<?php
namespace app\backend\controller;

class Subscriber extends Backend {
	
	public function index() {
		
		$view = \think\View::instance();
		
		$where = array();
		$condition = array();
		$view->assign('condition', $condition);
		
		$field = array(
			'subscriber.*',
		);
		$subscriber_select = \app\common\model\SubscriberModel::field($field)
			->where($where)->order('subscriber.id DESC')->paginate(10, false, array('query'=>$condition));
		$view->assign('page', $subscriber_select->render());
		
		$subscriber_list = array();
		foreach($subscriber_select as $SubscriberModel){
			$subscriber_list[] = $SubscriberModel->toArray();
		};
		$view->assign('data_list', $subscriber_list);
		
		unset($where, $condition, $field, $subscriber_select);
		return $view->fetch();
		
	}
	
}